home *** CD-ROM | disk | FTP | other *** search
- // SDisk v1.0, 9/17/93. (c)1993 DAS Software Publications
- // Registered copy
- #include <fstream.h>
- #include <process.h>
- #include <conio.h>
-
- void main(int argc, char * argv[])
- {
- if (argc != 2) {
- cerr<<"SDisk v1.0, 9/17/93. (c)1993 DAS Software Publications.\n";
- cerr<<"Registered copy\n\n";
- cerr<<"Usage: sdisk [drive:\\path\\filename]\n\n";
- cerr<<"Scans specified drive:\\path for file entered until found,\n";
- cerr<<"or user aborts with [return].\n";
- exit(-1);
- }
-
- char ch;
- int s_disk=1;
- ifstream infile;
-
- while (ch != '\r') {
- infile.open(argv[1]);
-
- cerr<<"\bInsert disk #"<<s_disk<<" and press any key..."<<endl;
-
- if (!infile) {
- cerr<<"File "<<argv[1]<<" NOT found."<<endl;
- } else {
- cout<<"File "<<argv[1]<<" found on disk #"<<s_disk<<endl;
- exit(-1);
- }
- s_disk++;
- ch = getche();
- }
- cerr<<"Scan aborted."<<endl;
- }
-
-
-
-